#include "OGLGlobals.h"
#include "DropletRenderer.h"
#include "OGLObjectData.h"


#include <gl/glew.h>
#include <glm/glm.hpp>
#include <cstdio>
#include <cstdlib>
#include <string>
#include <vector>
#define _USE_MATH_DEFINES
#include <cmath>
#include <sstream>

std::vector<GLenum> glfwEnableFlags;
std::vector<GLenum> glEnableFlags;

void scanInputArgs(int argc, char **argv)
{
}

void setEnableFlags(DropletRenderer *renderer)
{
	renderer->windowControl->glEnableFlags.push_back(GL_DEPTH_TEST);
//	renderer->windowControl->glEnableFlags.push_back(GL_CULL_FACE);
	renderer->windowControl->glfwEnableFlags.push_back(GLFW_STICKY_KEYS);
	renderer->windowControl->glfwEnableFlags.push_back(GLFW_SYSTEM_KEYS);
}

int main(int argc, char *argv[])
{
	scanInputArgs(argc, argv);
	DropletRenderer renderer = DropletRenderer();
	setEnableFlags(&renderer);	// Set Enable Flags for the Window Manager

	OGLResult retval = renderer.Launch();
	if(retval != OGL_SUCCESS)
	{
		fprintf(stderr, "[ERROR] Cleanup did not go smoothly.\n");
		return EXIT_FAILURE;
	}
	return EXIT_SUCCESS;
}